class Location:

    def __init__(self, row: int, column: int):
        self.lst = []
        self.row = row
        self.column = column
        self.maxValue = 0.0
        for r in range(row):
            self.lst.append([0])
            for c in range(column - 1):
                self.lst[r].append(0)

    def setElement(self, row: int, column: int, element: float or int):
        """
        设置表格中的元素
        :param row: 行
        :param column:列
        :param element: 元素
        :return: 无返回值
        """
        self.lst[row][column] = element

    def printList(self):
        """
        仅用于可视化表格
        :return: 无返回值
        """
        for i in self.lst:
            print(i)

    def getMaxValuePosition(self):
        """
        取表格中最大值所在的位置
        :return: 返回最大值及其所在的位置，其中位置以元组形式返回。
        """
        maxValue = 0
        pos = (0, 0)
        for r in self.lst:
            if maxValue < max(r):
                maxValue = max(r)
                pos = (self.lst.index(r), r.index(maxValue))
        return maxValue, pos


row, column = eval(input())
loc = Location(row, column)
for i in range(row):
    r = input().split()
    if len(r) > column:
        # print('你设定的列表止只有', column, '列，但你输入了', len(r), '列！')
        exit(0)
    for j in r:
        loc.setElement(i, r.index(j), eval(j))

maxValue, pos = loc.getMaxValuePosition()
print('The location of the largest element is ' + str(maxValue) + ' at ' + str(pos))
